Digital Average Input Current Control in Power Converter

ABSTRACT

A digital average-input current-mode control loop for a DC/DC power converter. The power converter may be, for example, a buck converter, boost converter, or cascaded buck-boost converter. The purpose of the proposed control loop is to set the average converter input current to the requested current. Controlling the average input current can be relevant for various applications such as power factor correction (PFC), photovoltaic converters, and more. The method is based on predicting the inductor current based on measuring the input voltage, the output voltage, and the inductor current. A fast cycle-by-cycle control loop may be implemented. The conversion method is described for three different modes. For each mode a different control loop is used to control the average input current, and the control loop for each of the different modes is described. Finally, the algorithm for switching between the modes is disclosed.

RELATED APPLICATIONS

This application claims priority from U.S. Provisional Application No.60/954,261 filed on Aug. 6, 2007 and U.S. Provisional Application No.60/954,354 filed on Aug. 7, 2007.

BACKGROUND

The subject invention relates to control loops for switching converters.The following articles and patents, which may or may not be prior art,and which are incorporated here by reference, may be relevant to thesubject invention.

-   Jingquan Chen, Aleksandar Prodic, Robert W. Erickson and Dragan    Maksimovic, “Predictive Digital Current Programmed Control”. IEEE    Transaction on Power Electronics, Vol. 18, No. 1, January 2003-   U.S. Pat. No. 7,148,669, “Predictive Digital Current Controllers for    Switching Power Converters” by Dragan Maksimovic, Jingquan Chen,    Aleksandar Prodic, and Robert W. Erickson.-   K Wallace, G Mantov, “DSP Controlled Buck/Boost Power Factor    Correction for Telephony Rectifiers”. INTELEC 2001, 14-18 Oct. 2001.-   U.S. Pat. No. 6,166,527, “Control Circuit and Method for Maintaining    High Efficiency in a Buck-Boost Switching Regulator” by David M.    Dwelley, and Trevor W. Barcelo.

Additionally, the following basic text is incorporated here byreference, in order to provide the reader with relevant art anddefinitions:

-   Robert W. Erickson, Dragan Maksimovic, “Fundamentals of Power    Electronics” (Second Edition), ISBN 0792372700.

SUMMARY

Aspects of the invention provide a method and system for digitallycontrolling the average input current in a non-inverting buck-boostconverter. The method provides a fast cycle-by-cycle control loop to setthe average input current when the converter is working in threedifferent modes: buck, buck-boost and boost. Unlike analog control whereit is difficult to change the parameters of the control loop in anadaptive manner, a digital control system can adjust the control loopparameters according to various parameters measured such as inputvoltage, output voltage and inductor current. In general, this enablesto achieve a fast and stable control loop that controls the inputcurrent in various working points of the converter.

Aspects of the invention also provide for a method and system fordigitally controlling the input current in a non-inverting (cascaded)buck-boost converter operating in a buck-boost mode, i.e., alternatingbetween buck and boost in each cycle. Such an operation mode isparticularly beneficial when the required converter output current issimilar to the converter's input current. Since there are limits to themaximal and minimal allowed PWM values of the buck or boost operationalmodes, there are areas in which control is impossible without use of thealternating buck-boost mode.

Aspects of the invention further provide for a method and system forcontrolling the operational mode switching of a cascaded buck-boostconverter. According to aspects of the invention, whenever the converterhas been operated in one mode, i.e., buck or boost, for at least apredetermined period, and is needed to change into the other operationalmode, i.e., to boost or buck, the transition is performed by forcing theconverter to first execute several cycles on alternating buck and boostmodes and only then switching to the other mode. Thus, for example, ifthe converter has been operating in a buck mode and is now to beswitched to a boost mode, it is first switched to operate in analternating buck-boost mode, in which the converter alternates by eachcycle between buck and boost modes for several cycles, and only thenswitches to boost mode. This feature avoids the current jumps ordiscontinuities that are generally observed when a converter switchesbetween buck and boost modes of operation.

Aspects of the invention further provide for a method and system forcontrolling the operation of a cascaded buck-boost converter, operablein one of three modes: buck, boost, and alternating buck-boost. Thesystem includes three preprogrammed PWM control modules, each forcontrolling the input current according to one of the converter'soperational modes. During operation of the converter, the operationalmode is determined and the corresponding PWM control module is selectedto control the input current.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 illustrate an example of a digital controlled non-invertingbuck-boost converter according to aspects of the invention.

FIG. 2 illustrates the waveforms of trailing triangle PWM modulation.

FIG. 3 illustrates the waveforms of leading triangle PWM modulation.

FIG. 4 shows the inductor current waveform during two switching cyclesusing trailing edge triangle PWM modulation.

FIG. 5 illustrates a block diagram of predictive buck input currentcontrol, according to embodiment of the invention.

FIG. 6 illustrates the inductor current waveforms for a buck-boostswitching cycle.

FIG. 7 illustrates the inductor current waveforms for a buck-boostswitching cycle according to embodiment of the invention.

FIG. 8 shows a block diagram of control loops for buck-boost inputcurrent control, according to embodiment of the invention.

FIG. 9 shows a state diagram and the possible options to switch betweenthe three different states.

DETAILED DESCRIPTION

A digital controlled non-inverting (cascaded) buck-boost converter, asdescribed in FIG. 1, is a topology for a converter that is capable ofboth increasing the input voltage and decreasing it. The proposedtopology is beneficial over prior art converters for at least thefollowing reasons: 1) high conversion efficiency can be achieved; 2)component stress is relatively low as apposed to other buck-boosttopologies; and 3) low component count—only one inductor, two capacitorsand four switches. When buck-boost converters are discussed in thisspecification, we typically refer to cascaded buck-boost topology,sometimes named “non-inverting buck-boost” converter, rather then thelower efficiency (inverting) buck-boost converter.

While in general control loops of converters the inductor current iscontrolled, according to an embodiment of the invention, a control loopis provided in order to set the average input current to the requestedcurrent (I_(ref)). Controlling the average input current can be relevantfor various applications such as: power factor correction (PFC),photovoltaic inverters, and more. In this example, the control is basedon predicting the inductor current for the next switching cycle based onmeasuring the input voltage (V_(ln)), the output voltage (V_(Out)) andthe inductor current (I_(L)) in the current switching cycle. By using apredictive method a fast, cycle-by-cycle, control loop can beimplemented.

Converter Modes

The cascaded buck-boost topology can achieve the desired input averagecurrent at various output currents. Depending on the output current, theconverter can work in 3 different modes:

-   -   I_(ref)>I_(out): Boost Converter—Switch A is constantly        conducting and switch B is not conducting.    -   2. I_(ref)<I_(out): Buck Converter—Switch D is constantly        conducting and switch C is not conducting.    -   3. I_(ref)≈I_(out): Buck-Boost Converter—All four switches are        being used to control the input current.

Each of the three modes may have a different control schemes. Thecontrol loop will decide which control scheme is used at each switchingcycle.

Predictive Average Input Current Control Using Triangle PWM Modulation

The control scheme of this example is based on predicting the inductorcurrent for the next switching cycle based on measuring the inductorcurrent and the input and output voltage. Based on the inductor currentthe control loop sets the average input current. Because of the factthat the predictive control loop is a non-linear control loop and it isexecuted on every PWM cycle, a high control bandwidth can be achieved.

The following sections will explain the concept of triangle PWMmodulation and the three control schemes mentioned above.

Triangle PWM Modulation

There are two types of triangle PWM modulation—leading and trialingtriangle modulation. FIG. 2 illustrates the waveforms of trailingtriangle PWM modulation.

Each cycle, having length T_(s) and a duty cycle of d, starts with anon-time of length d/2T_(s) an off-time of (1−d)T_(s) and another on-timeof the same length. Leading triangle modulation is similar but theon-time and off-times are switched, as shown in FIG. 3. Both methods aresuitable for input average current control because of the fact that theaverage inductor current is always at the beginning of each PWM cycle.This enables the digital control loop to sample the average inductorcurrent at fixed intervals, at the beginning of each cycle.

Controlling Average Input Current Using the Inductor Current

The method of this example uses the inductor current to set the averageinput current when the converting is operating in continuous conductionmode (CCM). The converter can work in one of three different modes—Buck,Boost, Buck-Boost. For each mode there is a different equation forconverting the average inductor current to the average input current ineach switching cycle. Derived from the power train properties of theconverter, the equations are:

Boost: Ĩ _(ln) =Ĩ _(L)  1.

Buck: Ī _(ln) =Ĩ _(L) *d, where d _(buck) is the duty cycle.  2.

Buck-Boost: Ĩ _(ln) =Ĩ _(L) *d _(buck), where d _(buck) is the buck dutycycle  3.

For all of the equations above Ĩ_(ln), Ĩ_(L) denote the average inputcurrent and average inductor current, respectively.

Control Loops

The converter works in 3 different modes. For each mode a differentcontrol loop is used to control the average input current. This sectionwill describe each control loop for the different modes. Later on, thealgorithm for switching between the modes will be described.

Predictive Boost Input Current Control

The goal of the control loop is to insure that the average input currentfollows the reference I_(ref). As described above, when the converteroperates in a boost mode the steady state average input current is thesame as the average inductor current. In this mode the boost controlwill try to set the average inductor current to I_(ref). The requiredboost duty cycle for the next switching cycle is predicted based on thesampled inductor current, the input voltage and the output voltage. FIG.4 shows the inductor current waveform during two switching cycles usingtrailing edge triangle PWM modulation. The sampled inductor current atswitching cycle n, i(n), can be calculated using the previous sample,i(n−1), and the input and output voltage. The calculation is based onthe inductor current slopes during the on-time and off-time.

Since the input and output voltage change slowly we assume that they areconstant during a switching cycle. For a boost converter the on-timeslope (m₁) and off-time slope (m₂) are given by the following equations:

$\begin{matrix}{m_{1} = \frac{V_{i\; n}}{L}} & (1) \\{m_{2} = \frac{V_{i\; n} - V_{out}}{L}} & (2)\end{matrix}$

Based on these equations we can predict i(n) using the followingequation:

$\begin{matrix}{{i_{pred}(n)} = {{i(n)} = {{i\left( {n - 1} \right)} + \frac{V_{i\; n}{d\lbrack n\rbrack}T_{s}}{L} + \frac{\left( {V_{i\; n} - V_{out}} \right){d^{\prime}\lbrack n\rbrack}T_{s}}{L}}}} & (3)\end{matrix}$

Where d′[n]=1−d[n], T_(s) is the switching cycle time and L is theinductor inductance. Equation (3) can also be written as:

$\begin{matrix}{{i_{pred}(n)} = {{i(n)} = {{i\left( {n - 1} \right)} + \frac{V_{out}{d\lbrack n\rbrack}T_{s}}{L} + \frac{\left( {V_{i\; n} - V_{out}} \right)T_{s}}{L}}}} & (4)\end{matrix}$

We now have the prediction equation for one switching cycle. Because ofthe fact that every digital implementation of the control loop will havean execution delay, we will extend the prediction to one more switchingcycle. So the prediction will set the duty cycle of the n+1 switchingcycle based on the samples of the n−1 switching cycle. Extendingequation (4) to two switching cycles we get:

$\begin{matrix}{{i\left( {n + 1} \right)} = {{i_{pred}(n)} + \frac{V_{out}{d\left\lbrack {n + 1} \right\rbrack}T_{s}}{L} + \frac{\left( {V_{i\; n} - V_{out}} \right)T_{s}}{L}}} & (5)\end{matrix}$

The prediction for the duty cycle d[n+1] can now be obtained based onthe values sampled in the previous switching period. By substitutingi(n+1) with the desired current I_(ref), in equation (5), and by solvingthe equation for d[n+1] we get:

$\begin{matrix}{{d\left\lbrack {n + 1} \right\rbrack} = {{\left( {I_{ref} - {i_{pred}(n)}} \right)\frac{L}{T_{s}*V_{out}}} + 1 - \frac{V_{i\; n}}{V_{out}}}} & (6)\end{matrix}$

Because of the fact that the inductor inductance can vary and to be ableto achieve a slower control loop, we modify equation (6) with a variablegain that can be pre-adjusted, and we get:

$\begin{matrix}{{d\left\lbrack {n + 1} \right\rbrack} = {{\left( {I_{ref} - {i_{pred}(n)}} \right)\frac{L*K}{T_{s}*V_{out}}} + 1 - \frac{V_{i\; n}}{V_{out}}}} & (7)\end{matrix}$

Equation (7) is the control law when the converter is in boost mode.

If we denote T_(i) as the beginning time of each switching cycle (i),the above method samples the input voltage, output voltage, and inductorcurrent at time T₀, utilizes the time until T₁ to predict the inductorcurrent at T₁ using the input voltage, output voltage and the knowledgeof the inductor inductance, and calculate the needed duty-cycle in orderto reach the desired input current (I_(ref)) at T₂, and set that dutycycle to be performed in the switching cycle between T₁ and T₂.

Predictive Buck Input Current Control

The principles of the predictive buck average input current control loopare similar to those of the boost current control loop. For the buckconverter, the on-time and off-time inductor slopes are given by thefollowing equations:

$\begin{matrix}{m_{1} = \frac{V_{i\; n} - V_{out}}{L}} & (8) \\{m_{2} = {- \frac{V_{out}}{L}}} & (9)\end{matrix}$

For switching cycle number n the average input current, based on theinductor current, is:

$\begin{matrix}{{\overset{\sim}{i}(n)} = {\left( {{i\left( {n - 1} \right)} + \frac{m\; 1{d\lbrack n\rbrack}{Ts}}{L} + \frac{m\; 2{d^{\prime}\lbrack n\rbrack}{Ts}}{L}} \right)*{d\lbrack n\rbrack}}} & (10)\end{matrix}$

Based on equations (8) and (9) we can predict the inductor current forone switching cycle, and get the following equation:

$\begin{matrix}{{i(n)} = {{i\left( {n - 1} \right)} + \frac{\left( {V_{i\; n} - V_{out}} \right){d\lbrack n\rbrack}T_{s}}{L} - \frac{V_{out}{d^{\prime}\lbrack n\rbrack}T_{s}}{L}}} & (11)\end{matrix}$

Combining equations (10) and (11) we get:

$\begin{matrix}{{\overset{\sim}{i}\left( {n + 1} \right)} = {\left( {{i\left( {n - 1} \right)} + \frac{V_{in}{d\lbrack n\rbrack}{Ts}}{L} - {2\frac{V_{out}{Ts}}{L}} + \frac{V_{in}{d\left\lbrack {n + 1} \right\rbrack}T_{s}}{L}} \right){d\left\lbrack {n + 1} \right\rbrack}}} & (12)\end{matrix}$

The prediction for the duty cycle d[n+1] can now be obtained based onthe values sampled in the previous switching period. Denoting thesampled current as i_(s)[n], and substituting the control objectiveĩ(n+1)=I_(ref) in (11), we have:

$\begin{matrix}{\left. {0 = {{{d^{2}\left\lbrack {n + 1} \right\rbrack}*\frac{V_{in}T_{s}}{L}} + {{d\left\lbrack {n + 1} \right\rbrack}\left\lbrack {{i\left( {n - 1} \right)} + \frac{V_{in}{d\lbrack n\rbrack}T_{s}}{L} - {2\frac{V_{out}T_{s}}{L}}} \right)}}} \right\rbrack - I_{ref}} & (13)\end{matrix}$

Equation (13) is the control law when the converter is in buck mode.Because of the fact that this equation is a quadratic equation, one ofthe methods of solving it in an efficient manner is to use NewtonRaphson method to approximate the solution.

If we denote T_(i) as the beginning time of each switching cycle (i),the above method samples the input voltage, output voltage, and inductorcurrent at time T₀, utilizes the time until T₁ to predict the inductorcurrent at T₁ using the input voltage, output voltage and the knowledgeof the inductor inductance, and calculate the needed duty-cycle in orderto reach the desired input current (I_(ref)) at T₂, that is dependent onthe inductor current and the duty cycle at T₂, and set that duty cycleto be performed in the switching cycle between T₁ and T₂.

Predictive Buck Input Current Control—Alternative Embodiment

Another method for controlling the converter's input current in a buckconverting is by controlling the inductor current and using theconverter's input and output voltage to set the correct inductorreference value in an adaptive manner. FIG. 5 shows the block diagram ofthe control loops for this method. Equation 14 holds true in steadystate in a buck converter:

$\begin{matrix}{{\overset{\sim}{I}}_{in} = {\frac{V_{out}}{V_{in}}{\overset{\sim}{I}}_{L}}} & (14)\end{matrix}$

By using equation (14) we can set the required inductor current (I_(L)_(—) _(Ref)) according to V_(in) and V_(out) in the following way:

$\begin{matrix}{I_{L\_ Ref} = {I_{ref}*\frac{V_{in}}{V_{out}}}} & (15)\end{matrix}$

Equation (15) is the feed-forward block that runs every switching cycle.After calculating the cycle-by-cycle inductor current reference, aninductor current loop is used to set the required inductor current.

Predictive Buck Inductor Current Control

By using equation (11), extending it for two switching cycles andreplacing i(n) with i_(pred)(n) we get the following equation:

$\begin{matrix}{{i\left( {n + 1} \right)} = {{i_{pred}(n)} + \frac{V_{in}{d\left\lbrack {n + 1} \right\rbrack}T_{s}}{L} - \frac{V_{out}T_{s}}{L}}} & (16)\end{matrix}$

By solving equation (16) for d[n+1] we get:

$\begin{matrix}{{d\left\lbrack {n + 1} \right\rbrack} = {{\left( {I_{L\_ ref} - {I_{pred}\lbrack n\rbrack}} \right)\frac{L}{T_{s}*V_{in}}} + \frac{V_{out}}{V_{in}}}} & (17)\end{matrix}$

Because of the fact that the inductor inductance can vary and to be ableto achieve a slower control loop, we modify equation (17) with avariable gain that can be pre-adjusted, and we get:

$\begin{matrix}{{d\left\lbrack {n + 1} \right\rbrack} = {{\left( {I_{L\_ ref} - {I_{pred}\lbrack n\rbrack}} \right)\frac{L*K}{T_{s}*V_{in}}} + \frac{V_{out}}{V_{in}}}} & (18)\end{matrix}$

Equation (18) is the control law for the buck inductor current loop.

If we denote T_(i) as the beginning time of each switching cycle (i),the above method samples the input voltage, output voltage, and inductorcurrent at time T₀, utilizes the time until T₁ to estimate the neededinductor current (I_(L) _(—) _(Ref)) according to the input voltage,output voltage and desired input current (I_(ref)). In addition,predicting the inductor current at T₁ using the input voltage, outputvoltage and the knowledge of the inductor inductance, and calculate theneeded duty-cycle in order to reach the needed inductor current (I_(L)_(—) _(ref)) at T₂, and set that duty cycle to be performed in theswitching cycle between T₁ and T₂.

Predictive Cascaded Buck-Boost Input Current Control

When the converter is in buck-boost mode all four switches are beingused to set the correct converter's average input current. This can beshown in FIG. 6 for trailing triangle PWM modulation. Switches B and Dare complementary to switches A and C respectively. In each switchingcycle both the buck and boost switches are being used to control theconverter's average input current. In general, the boost switches willoperate at a low duty cycle while the buck switches will operate at ahigh duty cycle.

FIG. 6 illustrates a method enabling the converter to set theconverter's average input current correctly when the output current isrelatively close to the reference current. In order to simplify thecontrol loop the buck duty cycle will be fixed to a value, d_(buck), andthe control loop will set the boost duty cycle every switching cycle.

FIG. 7 illustrates the inductor current waveforms for a buck-boostswitching cycle. The on-time and off-time inductor current slopes forthe buck cycle and boost cycle are identical to the equations in (8),(9) and (1), (2). In addition, the average input current can becalculated from the average inductor current with the followingequation:

Ĩ _(ln) =Ĩ _(L) *d _(buck)  (19)

Based on all these equations the predictive control law can be built forcalculating the required boost duty cycle:

$\begin{matrix}{{\overset{\sim}{i}(n)} = {\left( {{i\left( {n - 1} \right)} + \frac{\left( {V_{in} - V_{out}} \right)d_{buck}T_{s}}{L} - \frac{V_{out}d_{buck}^{\prime}T_{s}}{L} + \frac{V_{in}{d\lbrack n\rbrack}T_{s}}{L} + \frac{\left( {V_{in} - V_{out}} \right){d^{\prime}\lbrack n\rbrack}T_{s}}{L}} \right)d_{buck}}} & (20)\end{matrix}$

Denoting the sampled current as i_(s)[ ] substituting the controlobjective ĩ(n)=_(ref) in the equation above, and solving for d[n], weget the following:

$\begin{matrix}{{d\lbrack n\rbrack} = {2 + {\left( {\frac{i_{ref}}{d_{buck}} - {i_{s}\lbrack n\rbrack}} \right)\frac{L}{V_{out}T_{s}}} - {\frac{V_{in}}{V_{out}}d_{buck}}}} & (21)\end{matrix}$

Equation (21) is the control law for setting the boost duty cycle whenthe converter is in buck-boost mode.

If we denote T_(i) as the beginning time of each switching cycle (i),the above method samples the input voltage, output voltage, and inductorcurrent at time T₀, utilizes the time until T₁ to predict the inductorcurrent at T₁, based on the fact that the converter is in alternatingbuck-boost mode, using the input voltage, output voltage and theknowledge of the inductor inductance, and calculate the neededduty-cycle in order to reach the desired input current (I_(ref)) at T₂,and set that duty cycle to be performed in the switching cycle betweenT₁ and T₂.

Predictive Buck-Boost Input Current Control—Alternative Embodiment

Another method for controlling the converter's input current in acascaded buck-boost converting is by controlling the inductor currentand using the input and output voltage to set the correct inductorreference value in an adaptive manner. FIG. 8 shows the block diagram ofthe control loops for this method.

Predictive Buck-Boost Inductor Current Control

An efficient method of controlling the inductor current in a cascadedbuck-boost converter is setting a linear relation between the boost andbuck duty cycle in the following manner:

d _(buck)=1−c+d _(booct)  (22)

Where:

0≦c≦1

Using equations (1), (2), (8) and (9) we can estimate the inductor atthe end of switching cycle n:

$\begin{matrix}{{{i(n)} = {{i\left( {n - 1} \right)} + \frac{\left( {V_{in} - V_{out}} \right){d_{buck}\lbrack n\rbrack}T_{s}}{L} - \frac{V_{out}{d_{buck}^{\prime}\lbrack n\rbrack}T_{s}}{L} + \frac{V_{in}{d_{boost}\lbrack n\rbrack}T_{s}}{L} + \frac{\left( {V_{in} - V_{out}} \right){d_{boost}^{\prime}\lbrack n\rbrack}T_{s}}{L}}}{{i(n)} = {{i\left( {n - 1} \right)} + \frac{V_{in}{d_{buck}\lbrack n\rbrack}T_{s}}{L} + \frac{V_{out}{d_{boost}\lbrack n\rbrack}{Ts}}{L} + \frac{\left( {V_{in} - {2V_{out}}} \right){Ts}}{L}}}} & (23)\end{matrix}$

Combining equations (22) and (23) and we get:

$\begin{matrix}{{i_{pred}(n)} = {{i(n)} = {{i\left( {n - 1} \right)} + \frac{V_{in}{d_{boost}\lbrack n\rbrack}T_{s}}{L} + \frac{V_{out}{d_{boost}\lbrack n\rbrack}{Ts}}{L} + \frac{\left( {{V_{in}\left( {2 - c} \right)} - {2V_{out}}} \right){Ts}}{L}}}} & (24)\end{matrix}$

By extending equation (24) to another switching cycle we get:

$\begin{matrix}{{i\left( {n + 1} \right)} = {{i_{pred}(n)} + \frac{V_{in}{d_{boost}\left\lbrack {n + 1} \right\rbrack}T_{s}}{L} + \frac{V_{out}{d_{boost}\left\lbrack {n + 1} \right\rbrack}{Ts}}{L} + \frac{\left( {{V_{in}\left( {2 - c} \right)} - {2V_{out}}} \right){Ts}}{L}}} & (25)\end{matrix}$

Solving equation (25) for d_(boost)[n+1] and replacing i(n+1) with thecontrol objective, I_(L) _(—) _(Ref), we get:

$\begin{matrix}{{d_{boost}\left\lbrack {n + 1} \right\rbrack} = {{\left( {i_{L\_ Ref} - {i\left( {n - 1} \right)}} \right)*\frac{L*K}{\left( {V_{out} + V_{in}} \right)*{Ts}}} - \frac{\left( {{V_{in}\left( {2 - c} \right)} - {2V_{out}}} \right)}{V_{out} + V_{in}}}} & (26)\end{matrix}$

Equation (26) is the control law for the inductor current control in acascaded buck-boost converter.

Feed Forward

In order to control the converter's input current, a cycle by cyclefeed-forward is used in order to change the inductor current referenceaccording to the required converter input current and input and outputvoltage. In a cascaded buck-boost converter we know that in steadystate:

$\begin{matrix}{\frac{V_{out}}{V_{in}} = \frac{D_{buck}}{1 - D_{boost}}} & \left( {27a} \right) \\{\frac{{\overset{\sim}{i}}_{in}}{{\overset{\sim}{i}}_{l}} = D_{buck}} & \left( {27b} \right)\end{matrix}$

Using equations (27) and (22) we can get:

$\begin{matrix}{i_{L\_ Ref} = {i_{ref}\frac{V_{in} + V_{out}}{\left( {2 - c} \right)V_{out}}}} & (28)\end{matrix}$

Using equation (28) we can set the required inductor current accordingto the desired input current and input and output voltages.

If we denote T_(i) as the beginning time of each switching cycle (i),the above method samples the input voltage, output voltage, and inductorcurrent at time T₀, utilizes the time until T₁ to estimate the neededinductor current (I_(L-Ref)) according to the input voltage, outputvoltage and desired input current (I_(ref)). In addition, predicting theinductor current at T₁ using the input voltage, output voltage and theknowledge of the inductor inductance, and calculate the neededduty-cycle in order to reach the needed inductor current (I_(L) _(—)_(ref)) at T₂, and set that duty cycle to be performed in the switchingcycle between T₁ and T₂.

Switching Between Converter Modes

The converter needs to switch between three different modes depending onthe reference current and the output current. FIG. 9 shows a statediagram and the possible options to switch between the three differentstates. The following sections will describe the logic from switchingbetween the different states.

Switching from Buck Mode

When in buck mode, the duty cycle will be monitored every switchingcycle. If the duty cycle is higher than the threshold set,0<Th_(bucl)<1, for more than X_(buck) consecutive switching cycles theconverter will switch to buck-boost mode.

Switching from Buck-Boost Mode

When in buck-boost mode, the duty cycle of the boost converter will bemonitored every boost switching cycle (every second switching cycle).Two thresholds will be set −Th_(high) and Th_(low). If the duty cycle ishigher than Th_(high) for more than X_(high) consecutive switchingcycles the converter will switch to boost mode. If the duty cycle islower than Th_(low) for more than X_(low) consecutive switching cyclesthe converter will switch to buck mode.

Switching from Boost Mode

When in boot mode, the duty cycle will be monitored every switchingcycle. If the duty cycle is lower than the threshold set,0<Th_(boost)<1, for more than X_(boost) consecutive switching cycles theconverter will switch to buck-boost mode.

1-20. (canceled)
 21. A method, comprising: sampling an inductor currentof an inductor of a converter; sampling an input voltage of theconverter; sampling an output voltage of the converter; predicting, by acontroller, the inductor current based on the sampled inductor current,the sampled input voltage, and the sampled output voltage; andcontrolling a duty cycle based on the predicted inductor current tocause an input current of the converter to approach a desired inputcurrent.
 22. The method of claim 21, wherein predicting the inductorcurrent comprises predicting the inductor current for a second cyclebased on the sampled inductor current for a first cycle.
 23. The methodof claim 22, wherein controlling the duty cycle comprises controllingthe duty cycle for the second cycle.
 24. The method of claim 21, whereincontrolling the duty cycle comprises performing a triangle pulse widthmodulation.
 25. The method of claim 21, wherein the converter comprisesa cascaded buck-boost converter.
 26. The method of claim 21, wherein thecontroller comprises a first pre-programmed control module for a buckmode of the converter, a second pre-preprogrammed control module for aboost mode of the converter, and a third pre-programmed control modulefor an alternating buck-boost mode of the converter.
 27. The method ofclaim 21, wherein the controller comprises three pre-programmed controlmodules for controlling the input current of the converter according tothree operational modes of the converter, respectively.
 28. The methodof claim 21, further comprising: transferring the converter from a firstoperational mode to a second operational mode in response to a dutycycle dropping below or climbing above a threshold.
 29. The method ofclaim 21, further comprising: transferring the converter from analternating buck-boost mode to a buck mode or a boost mode in responseto a duty cycle dropping below or climbing above a threshold for atleast a predetermined number of cycles.
 30. An apparatus, comprising: acircuit configured to: sample an inductor current of an inductor of aconverter; sample an input voltage of the converter; and sample anoutput voltage of the converter; a controller configured to: predict theinductor current based on the sampled inductor current, the sampledinput voltage, and the sampled output voltage; and control a duty cyclebased on the predicted inductor current to cause an input current of theconverter to approach a desired input current.
 31. The apparatus ofclaim 30, wherein predicting the inductor current comprises predictingthe inductor current for a second cycle based on the sampled inductorcurrent for a first cycle.
 32. The apparatus of claim 31, whereincontrolling the duty cycle comprises controlling the duty cycle for thesecond cycle.
 33. The apparatus of claim 30, wherein controlling theduty cycle comprises performing a triangle pulse width modulation. 34.The apparatus of claim 30, further comprising the converter, wherein theconverter comprises a cascaded buck-boost converter, and wherein thecontroller comprises a first pre-programmed control module for a buckmode of the converter, a second pre-preprogrammed control module for aboost mode of the converter, and a third pre-programmed control modulefor an alternating buck-boost mode of the converter.
 35. The apparatusof claim 30, wherein the controller is further configured to: transferthe converter from a first operational mode to a second operational modein response to a duty cycle dropping below or climbing above athreshold.
 36. A method, comprising: predicting, by a controller, aninductor current of an inductor of a converter; and controlling a dutycycle based on the predicted inductor current to cause an input currentof the converter to approach a desired input current; and
 37. The methodof claim 36, further comprising: transferring the converter from analternating buck-boost mode to a buck mode or a boost mode in responseto the duty cycle dropping below or climbing above a threshold for atleast a predetermined number of cycles.
 38. The method of claim 37,wherein the transferring depends at least on the desired input current.39. The method of claim 37, wherein the predicting of the inductorcurrent is performed according to an algorithm that depends on whetherthe converter is in the alternating buck-boost mode, the buck mode, orthe boost mode.
 40. The method of claim 36, wherein the predicting ofthe inductor current is performed according to an algorithm that dependson whether the converter is in an alternating buck-boost mode, a buckmode, or a boost mode.